<!DOCTYPE html>
<html lang="en" xmlns:th="http://www.thymeleaf.org">
<head>
    <meta charset="UTF-8">
    <title>MyDessertStore</title>
    <link rel="StyleSheet" href="/css/mydessertstore.css" type="text/css"
          media="screen"/>
    <link rel="StyleSheet" href="/css/categorybutton.css" type="text/css"
          media="screen"/>
    <link rel="StyleSheet" href="/css/searchAutoComplete.css" type="text/css"
          media="screen"/>
    <link rel="StyleSheet" href="/css/searchHover.css" type="text/css"
          media="screen"/>
    <link rel="StyleSheet" href="/css/newOrder.css" type="text/css"
          media="screen"/>
    <link rel="stylesheet" href="/css/floating_window.css"/>
    <script src="http://cdn.bootcdn.net/ajax/libs/jquery/3.6.1/jquery.min.js"></script>
</head>

<body>
<header th:fragment="header">

    <div id="Header">

        <div id="Logo">
            <div id="LogoContent">
                <a href="/mainForm"><img src="/images/logo_2.png"></a>
            </div>
        </div>

        <div id="Menu">
            <div id="MenuContent">
                <ul class="shell">
                    <a href="/main"><img class="top_pic" src="/images/home.png">&ensp;首页</a>
                    <a href="/cartForm"><img class="top_pic" src="/images/cart.png">&ensp;购物车</a>
                    <li class="shellbutton">
                        <span><img class="top_pic" src="/images/category.png">&ensp;分类</span>
                        <ul>
                            <li><a href="/categoryForm?categoryId=CHEESS">乳酪</a></li>
                            <li><a href="/ategoryForm?categoryId=CHOCOLATE">巧克力</a></li>
                            <li><a href="/categoryForm?categoryId=FRUIT">水果</a></li>
                            <li><a href="/categoryForm?categoryId=MUSI">慕斯</a></li>
                            <li><a href="/categoryForm?categoryId=NUT">坚果</a></li>
                        </ul>
                    </li>

                    <a th:if="${session.account} != null" th:href="@{listOrders(username=${session.account.username})}"><img class="top_pic"
                                                                                        src="/images/order.png">&ensp;我的订单</a>
                    <a th:if="${session.account} != null" href="/editAccountForm"><img class="top_pic" src="/images/myinf.png">&ensp;我的信息</a>


                    <a href="/our.html"><img class="top_pic" src="/images/our.png"> 关于我们</a>

                </ul>

            </div>
        </div>


        <div id="Search">
            <div id="SearchContent">
                <form action="/searchProducts" method="post">
                    <input id="SearchBox" type="text" name="keyword" placeholder="输入并检索" size="14">
                    <input id="SeachSubmit" type="submit" name="searchProducts" value=" ">
                    &nbsp;

                    <a th:if="${session.account} == null" href="/signonForm">登录</a>
                    <a th:if="${session.account} == null" href="/registerForm">注册</a>&nbsp&nbsp&nbsp&nbsp&nbsp


                    <a th:if="${session.account} != null " href="/signOut">登出</a>&ensp;&ensp;&ensp;&ensp;&ensp;&ensp;

                </form>
                <div id="productAutoComplete">
                    <li class="autoshell">
                        <ul id="productList">
                            <%--
                            <li class="productAutoItem">heifan</li>
                            <li class="productAutoItem">chess</li>
                            <li class="productAutoItem">dangao</li>
                            --%>


                        </ul>

                    </li>
                </div>
            </div>
        </div>

    </div>

</header>
</body>
</html>